package com.chenxingnet.service;


import java.util.List;

import javax.servlet.http.HttpServletRequest;

import org.springframework.ui.Model;

import com.chenxingnet.dto.Cars;

public interface CarsService {
	/**
	 * 新增车辆信息
	 * @param cars
	 */
	int insertCars(Cars cars);
	/**
	 * 修改车辆信息
	 */
	int updateCars(Cars cars);
	/**
	 * 根据id删除车辆信息
	 */
	int deleteCars(Integer cid);
	/**
	 * 根据id查询车辆信息
	 */
	Cars selectById(Integer cid);
	
	/**
	 * 分页查询车辆信息
	 */
	void selectAllByCount(HttpServletRequest request, Model model);
	
	/**
	 * 移动端分页查询车辆信息
	 */
	void mobSelectAllByCount(HttpServletRequest request);
	
	/*
	 * 获取所有有效的车辆信息
	 */
	List<Cars> getAllCars();
	//根据始发地查询目的地
	List<Cars> selectByCommon(String comCity);
	List<Cars> getCarsByChufadi(String chufadi);
	List<Cars> getChexingnByDeparture(String chufadi, String mudi);
	List<Cars> getQushuByDeparture(String chufadi, String mudi, String chexing);
	List<Cars> getChangjiaByDeparture(String chufadi, String mudi,
			String chexing, String qushu);
	List<Cars> getJiashiJiesuanByDeparture(String chufadi, String mudi,
			String chexing, String qushu, String changjiajiesuan);
	
	
	

}
